package cn.moningxi.service.impl;

import cn.moningxi.bean.SystemMenu;
import cn.moningxi.mapper.SystemMenuMapper;
import cn.moningxi.service.SystemMenuService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class SystemMenuServiceImpl implements SystemMenuService {

    @Autowired
    private SystemMenuMapper systemMenuMapper;

    /**
     * 根据系统管理员的id查询出该管理员所拥有的全部功能菜单
     *
     * @param userId
     * @return
     */
    @Override
    public List<SystemMenu> queryMenuListByUserId(Integer userId) {
        return systemMenuMapper.queryMenuListByUserId(userId);
    }
}
